package com.escool.service;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.escool.dao.ProfAlumnoDAO;

import com.escool.model.TbExpedienteHasRecord;
import com.escool.model.TbMensaje;
import com.escool.model.TbRecord;

@Service
public class ProfAlumnoServiceImpl implements ProfAlumnoService {

	@Autowired
	ProfAlumnoDAO profAlumnoDAO;

	@Transactional
	public void addMsg(TbMensaje msg) {
		profAlumnoDAO.addMsg(msg);

	}

	@Transactional
	public List<TbMensaje> listMsg() {
		
		return profAlumnoDAO.listMsg();
	}

	@Transactional
	public TbMensaje findMsgById(Integer id) {
		
		return profAlumnoDAO.findMsgById(id);
	}

	@Transactional
	public void addRecord(TbRecord rec) {
		profAlumnoDAO.addRecord(rec);
		
	}

	@Transactional
	public List<TbRecord> listAllRecord() {
		
		return profAlumnoDAO.listAllRecord();
	}

	@Transactional
	public TbRecord findRecordById(Integer id) {
		 
		return profAlumnoDAO.findRecordById(id);
	}

	@Transactional
	public void addExpRec(TbExpedienteHasRecord exprec) {
		profAlumnoDAO.addExpRec(exprec);
		
	}

	@Transactional
	public List<TbExpedienteHasRecord> listExpedienteRecordByIdExpediente(
			String id) {
		
		return profAlumnoDAO.listExpedienteRecordByIdExpediente(id);
	}

	@Transactional
	public List<TbExpedienteHasRecord> listExpedienteRecord() {
		// TODO Auto-generated method stub
		return profAlumnoDAO.listExpedienteRecord();
	}
}
